package net.yangyy.os.user.api;

import com.alibaba.csp.sentinel.slots.block.BlockException;
import lombok.extern.slf4j.Slf4j;
import net.yangyy.os.common.resp.ResultData;

/**
 * @author zhaox 2021/7/14
 * @version 1.0.0
 */
@Slf4j
public class BaseApi {

    public ResultData sentinelException(BlockException blockException){
      log.warn("限流监控异常:{}",blockException.getClass().getCanonicalName());
      return ResultData.fail(900,"访问频繁，请稍候!");
    }
}
